package shuixian.jing.discuz.activity;

import shuixian.jing.discuz.R;
import shuixian.jing.discuz.activity.base.FrameActivity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;

public class DiscuzAppActivity extends FrameActivity implements OnClickListener{
    /** Called when the activity is first created. */
	private static final String TAG = "DiscuzAppActivity";
	private int mOnClickViewId ; //点击控件的ID
	private Intent mIntent;  //公用Intent
	private Button mButtonLogin ; //登陆
	
	@Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
        initView();
        initListeners();
    }
	
    @Override
	protected void initView() {
		super.initView();
		mButtonLogin = (Button)findViewById(R.id.button_login);
	}

	@Override
	protected void initListeners() {
		super.initListeners();
		mButtonLogin.setOnClickListener(this);
	}

	

	public void onClick(View pView) {
		mOnClickViewId = pView.getId();
		showToast(""+mOnClickViewId);
		switch (mOnClickViewId) {
		case R.id.button_login: //login
			mIntent = new Intent(this, ActivityLogin.class);
			startActivity(mIntent);
			break;

		default:
			break;
		}
	}
}